home *** CD-ROM | disk | FTP | other *** search
/ MacWorld 1998 May / Macworld (1998-05).dmg / Updaters / SoftWindows 95 5.0.2 / SoftWindows Upgrade Disk / SoftWindows Upgrade Disk / UNIX.BAT < prev    next >
DOS Batch File  |  1998-02-17  |  4KB  |  115 lines

  1. rem [
  2. rem    Name:        u.unix.bat
  3. rem
  4. rem    Derived from:    mac.bat
  5. rem
  6. rem    Author:        Clive Standbridge
  7. rem
  8. rem    Created on:    Oct 1996
  9. rem
  10. rem    Sccs ID:    @(#)u.unix.bat    1.12 06/20/97
  11. rem
  12. rem    Coding Stds:    
  13. rem
  14. rem    Purpose:    Batch file for updating Unix-specific parts of
  15. rem            SoftWindows and SoftPC Turbo.
  16. rem
  17. rem    Parameters:    1    Windows version; must be "win31" or "win95".
  18. rem                (win31 includes WfW 3.11).
  19. rem            2    Windows system directory.
  20. rem            3     two-letter language ID
  21. rem            4    Host System name
  22. rem            5    Host System release
  23. rem            6    Host System version
  24. rem            7    Host System hardware type
  25. rem
  26. rem    Copyright 1997 Insignia Solutions PLC. All rights reserved.
  27. rem ]
  28.  
  29.  
  30. goto %1
  31. rem should never get here!
  32. goto end
  33.  
  34. :win31
  35. rem  Check for SoftWindows 2.0 self-modifying autoexec.bat file
  36. rem  We will find this if the user creates a new disk from a
  37. rem  Swin 2 disk data file. We need to convert the SWIN2HOME
  38. rem  to SWINHOME. NB this file is the same for US, French and German.
  39. filecomp c:\autoexec.bat d:\unixonly\sw2auto.unx            >>c:\insignia\up.log
  40. if errorlevel 1 goto not_sw2
  41. echo Converting autoexec.bat from SoftWindows 2.0 version        >>c:\insignia\up.log
  42. move c:\autoexec.bat c:\autoexec.tmp                    >>c:\insignia\up.log
  43. keybconf d:\unixonly\swinhome.def c:\autoexec.tmp c:\autoexec.bat    >>c:\insignia\up.log
  44. del c:\autoexec.tmp                            >>c:\insignia\up.log
  45. :not_sw2
  46.  
  47. rem  Set up the selected keyboard in the upgrade script, then run it.
  48. keybconf c:\insignia\keyboard.def d:\unixonly\unix311.ugd c:\insignia\unix311.ugd    >>c:\insignia\up.log
  49. win31lic /v /s%2 c:\insignia\unix311.ugd    >>c:\insignia\up.log
  50. goto end
  51.  
  52. :win95
  53. REM  What I really want to do is to modify win95lic to take multiple .ugd files.
  54. REM  We could generate runonce.reg to invoke w95once.bat with a host parameter.
  55. REM  For the time being we append to the hard-coded file name.
  56. type c:\insignia\unix95.ugd    >> c:\insignia\win95.ugd
  57.  
  58. rem  If we have a non-US keyboard selected, set up the keyboard selection from
  59. rem  a template UGD file and the selected keyboard.def file.
  60. set w95_locale_no=xxxxxxxxxxxxxxxxxxxx
  61. find "W95_LOCALE_NO=" < c:\insignia\keyboard.def | ibatch w95_locale_no string 14 0
  62. if "%w95_locale_no%" == ""         goto no_intl_kbd
  63. keybconf c:\insignia\keyboard.def d:\unixonly\u95kbd.ugd c:\insignia\u95kbd.tmp        >>c:\insignia\up.log
  64. type c:\insignia\u95kbd.tmp    >> c:\insignia\win95.ugd
  65.  
  66. rem  If we also have one of the host-specific keyboard layouts selected,
  67. rem  set up the keyboard layout from a template UGD file and the selected
  68. rem  keyboard.def file.
  69. set w95_sublocale=xxxxxxxxxxxxxxxxxxxx
  70. find "W95_SUBLOCALE=" < c:\insignia\keyboard.def | ibatch w95_sublocale string 14 0
  71. if "%w95_sublocale%" == ""         goto no_intl_kbd
  72. keybconf c:\insignia\keyboard.def d:\unixonly\u95kbd_2.ugd c:\insignia\u95kbd_2.tmp    >>c:\insignia\up.log
  73. type c:\insignia\u95kbd_2.tmp    >> c:\insignia\win95.ugd
  74.  
  75. :no_intl_kbd
  76. set w95_locale_no=
  77. set w95_sublocale=
  78.  
  79. rem Need to check to see if we are doing a SGI Japanese Win95 upgrade. If so
  80. rem we need to setup the user selected keyboard type
  81. set w95j_new106keyboard=xxxxxxxxxxxxxxxxxxxx
  82. find "NEW106KEYBOARD=" < c:\insignia\keyboard.def | ibatch w95j_new106keyboard string 15 0
  83. if "%w95j_new106keyboard%" == ""         goto no_j_kbd
  84. keybconf c:\insignia\keyboard.def d:\unixonly\u95kbdj.ugd c:\insignia\u95kbdj.tmp    >>c:\insignia\up.log
  85. type c:\insignia\u95kbdj.tmp    >> c:\insignia\win95.ugd
  86.  
  87. :no_j_kbd
  88. set w95j_new106keyboard=
  89.  
  90. rem  ===================
  91. rem  Miscellaneous stuff
  92. rem  ===================
  93.  
  94. rem  SGI bits. From IRIX 6.4 "uname -s" irritatingly returns the version
  95. rem  appended to the OS name.
  96. set os_name=xxxx
  97. ibatch os_name string %4 0 4
  98. if not "%os_name%" == "IRIX" goto no_IRIX
  99.  
  100. rem  SGI AVI driver and associated bits
  101. copy d:\unixonly\misc\avioff.bat    c:\insignia    >>c:\insignia\up.log
  102. copy d:\unixonly\misc\avion.bat        c:\insignia    >>c:\insignia\up.log
  103. copy d:\unixonly\misc\mciavi.drv    c:\insignia    >>c:\insignia\up.log
  104. rem  Save original AVI driver for avion/avioff batch files.
  105. if not exist c:\insignia\mciavi.org copy c:\windows\system\mciavi.drv c:\insignia\mciavi.org    >>c:\insignia\up.log
  106.  
  107. rem  SGI Japanese support information.
  108. if "%3" == "jp" copy d:\unixonly\misc\oeminfo.nsg c:\windows\system\oeminfo.ini    >>c:\insignia\up.log
  109.  
  110. :no_IRIX
  111. set os_name=
  112. goto end
  113.  
  114. :end
  115.